<?php
function createZendDbTable($tableName,$outputFilePath) {
    $fileName = ucfirst($tableName);
    $className = "Application_Model_DbTables_" . ucfirst($tableName);
    $class = "class " . $className . " extends Zend_Db_Table_Abstract {\n";
    $class .= "    protected \$_name = \"" . $tableName . "\";\n";
    $class .= "}";

    if (file_exists($outputFilePath)) unlink($outputfile);

    $fileHandle = fopen($outputFilePath, 'w') or die("can't open file");
    fwrite($fileHandle, '<?php'.$class);
    fclose($fileHandle);
}
?>
